<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div id="app">
        <div v-if="msg ==='test'">这是if控制的div</div>
        <div v-show="true">这是show控制的div</div>

        <!-- for -->
        <div v-for="(item,index) in arr">
            {{item}}{{index}}
            <span v-show="item!=='mick'">----这是{{item}}的介绍</span>
        </div>
    </div>
    <script src="./js/vue.js"></script>
    <script>
        var app = new Vue({
            el: '#app',
            data: {
                msg: 'test',
                ifvisible: true,
                showvisible: true,
                arr: ['tom', 'jock', 'mick', 'rose']
            }
        })
    </script>
</body>

</html>